<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="../../pccommon.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>个人中心收货地址</title>
<link type="text/css" rel="stylesheet" href="${staticPath}/pccss/grzx.css" />
<script type="text/javascript" src="${staticPath}/js/app/address/pcaddress.js"></script>
</head>
<body>
	<div id="wrapper">
		<c:import url="../layout/header2.jsp"></c:import>
		<div id="main">
			<div id="mainw">
				<c:import url="../layout/leftNav.jsp">
					<c:param name="leftNav" value="address" />
				</c:import>
				<div class="mainw_right">
					<div class="mainw_right1">
						<img src="${staticPath}/pcimages/a1.png" />
						<h1>收货地址</h1>
					</div>
					<div class="mainw_right8">
						<table class="table1" style="width: 900px; border: 0px;">
							<tr class="td1">
								<td style="width: 140px; text-align: center;">
									<input type="button" class="td1b tc" value="+新建收货地址" />
								</td>
								<td style="width: 380px; text-align: center;"></td>
								<td style="width: 140px; text-align: center;"></td>
								<td style="width: 240px; text-align: center;"></td>
							</tr>
							<tr class="td1">
								<td style="width: 140px; text-align: center;">收货人</td>
								<td style="width: 380px; text-align: center;">详细地址</td>
								<td style="width: 140px; text-align: center;">电话</td>
								<td style="width: 240px; text-align: center;">操作</td>
							</tr>
							<c:forEach items="${addressList}" var="address">
								<tr class="td1">
									<td style="width: 140px; text-align: center;">${address.name }</td>
									<td style="width: 380px; text-align: center;">${address.address }</td>
									<td style="width: 140px; text-align: center;">${address.mobPhone }</td>
									<td style="width: 240px; text-align: center;">
										<c:if test="${address.isDefault == '0' }">
											<a href="javascript:setDefault('${address.id }');" class="td1a">设为默认地址</a>
										</c:if>
										<c:if test="${address.isDefault == '1' }">
											<span class="td1s"> 默认地址 </span>
										</c:if>
										<a href="javascript:edit('${address.id }')" class="td1a">编辑</a>
										<c:if test="${address.isDefault == '0' }">
											<a href="javascript:del('${address.id }');" class="td1a">删除</a>
										</c:if>
									</td>
								</tr>
							</c:forEach>
						</table>
						<div class="popup2" id="popup1">
						</div>
					</div>
				</div>
			</div>
		</div>
		<c:import url="../layout/footer.jsp"></c:import>
	</div>
</body>
</html>
